package com.spzx.product.api.domain;

import com.spzx.common.core.web.domain.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.Email;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

/**
 * 实体类。数据模型类。
 * 品牌类
 */
@Data
@Schema(description = "品牌信息类")
public class Brand extends BaseEntity {

    @Schema(description = "品牌名称")
    @NotBlank(message = "品牌名称不能为空")  //不能是null,也不能是长度为0
    @Size(min = 0,max = 64,message = "品牌名称在0~64长度之内")
    private String name;

    @Schema(description = "品牌图标")
    @NotBlank(message = "品牌图标不能为空")  //不能是null,也不能是长度为0
    @Size(min = 0,max = 256,message = "品牌图标在0~256长度之内")
    private String logo;
}
